﻿namespace Framework.Core.Extension
{
	/// <summary>
	/// HttpContext扩展类
	/// </summary>
	public static class HttpContextExtension
	{
		/// <summary>
		/// 获取登录用户名
		/// </summary>
		/// <param name="context"></param>
		/// <returns></returns>
		public static string GetName(this HttpContext context)
		{
			var uid = context.User?.Identity?.Name;
			return uid;
		}
	}
}
